package zuoye2;

import java.util.ArrayList;
import java.util.Random;

public class zuoye06 {
		public static void main(String[] args){
			ArrayList<Integer> list1=new ArrayList<Integer>();
			list1=geShi(7);
		}
		public static ArrayList<Integer> geShi(int count){
			ArrayList<Integer> list=new ArrayList<Integer>();
			for(int i=0;list.size()<count;i++){
				Random r=new Random();
				int a=r.nextInt(33)+1;
				if(!list.contains(a)){
					list.add(a);
				}
			}
			System.out.print("{");
			for(int i=0;i<count;i++){
				if(i<count-1){
					System.out.print(list.get(i)+"@");
				}else if(i==count-1){
					System.out.print(list.get(i));
				}	
			}
			System.out.print("}");
			return list;
		}

}
